package com.tonann.app.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.tonann.common.annotation.Excel;
import com.tonann.common.core.domain.BaseEntity;

/**
 * 运行网关对象 app_gateway
 * 
 * @author kunchan
 * @date 2022-10-09
 */
public class AppGateway extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** ID */
    private Long gatewayId;

    /** 上级网关ID */
    @Excel(name = "上级网关ID")
    private Long pid;

    /** 网关类型 1-PLC 2-MQTT 3-网关设备 */
    @Excel(name = "网关类型 1-PLC 2-MQTT 3-网关设备")
    private String gatewayType;

    /** 网关编号 */
    @Excel(name = "网关编号")
    private String gatewayCode;

    /** 网关名字 */
    @Excel(name = "网关名字")
    private String gatewayName;

    /** 网关IP地址 */
    @Excel(name = "网关IP地址")
    private String ipAddress;

    /** 网关IP地址 */
    @Excel(name = "网关IP地址")
    private String port;

    /** 网关状态 */
    @Excel(name = "网关状态")
    private String status;

    /** 是否删除 */
    private String delFlag;

    private AppGateway parentGateway;

    public void setGatewayId(Long gatewayId) 
    {
        this.gatewayId = gatewayId;
    }

    public Long getGatewayId() 
    {
        return gatewayId;
    }
    public void setPid(Long pid) 
    {
        this.pid = pid;
    }

    public Long getPid() 
    {
        return pid;
    }
    public void setGatewayType(String gatewayType){ this.gatewayType = gatewayType;  }

    public String getGatewayType()
    {
        return gatewayType;
    }
    public void setGatewayCode(String gatewayCode) 
    {
        this.gatewayCode = gatewayCode;
    }

    public String getGatewayCode() 
    {
        return gatewayCode;
    }
    public void setGatewayName(String gatewayName) 
    {
        this.gatewayName = gatewayName;
    }

    public String getGatewayName() 
    {
        return gatewayName;
    }
    public void setIpAddress(String ipAddress) 
    {
        this.ipAddress = ipAddress;
    }

    public String getIpAddress() 
    {
        return ipAddress;
    }
    public void setPort(String port) 
    {
        this.port = port;
    }

    public String getPort() 
    {
        return port;
    }
    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }
    public void setDelFlag(String delFlag) 
    {
        this.delFlag = delFlag;
    }

    public String getDelFlag() 
    {
        return delFlag;
    }

    public AppGateway getParentGateway() {
        return parentGateway;
    }

    public void setParentGateway(AppGateway parentGateway) {
        this.parentGateway = parentGateway;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("gatewayId", getGatewayId())
            .append("pid", getPid())
            .append("gatewayType", getGatewayType())
            .append("gatewayCode", getGatewayCode())
            .append("gatewayName", getGatewayName())
            .append("ipAddress", getIpAddress())
            .append("port", getPort())
            .append("status", getStatus())
            .append("delFlag", getDelFlag())
            .append("createBy", getCreateBy())
            .append("updateBy", getUpdateBy())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
